import Vue from 'vue';
import Router from 'vue-router';
import Index from '../views/index.vue';
import Modules from '../views/modules.vue';
import signInList from '../views/signInList/signInList'
import sjInfoList from "../views/sjInfo/sjInfoList";
import sjAdd from "../views/sjInfo/modules/sjAdd";
import choosedSjjd from "../views/sjInfo/modules/choosedSjjd";
import calendarList from "../views/calendarList/calendarList";
import calendarDetail from "../views/calendarList/calendarDetail";
import myTaskList from "../views/myTask/myTaskList";
import myTaskAdd from "../views/myTask/modules/myTaskAdd";
import customerList from "../views/customer/customerList";
import customerAdd from "../views/customer/modules/customerAdd";
import searchSjInfoList from "../views/customer/searchSjInfoList";

Vue.use(Router)

export default new Router({
  // base: '/JDL/',
  routes: [
    {
      path: '/',
      name: 'Index',
      component: Index
    },
    {
      path: '/modules',
      name: 'modules',
      component: Modules
    },
    {
      path: '/signInList',
      name: 'signInList',
      component: signInList,
    },
    {
      path: '/sjInfoList',
      name: 'sjInfoList',
      component: sjInfoList,
    },
    {
      path: '/sjAdd/:isAdd?/:id?/:isDetail?/:fnewjd?/:fnewnodeid?',
      name: 'sjAdd',
      component: sjAdd,
    },
    {
      path: '/choosedSjjd',
      name: 'choosedSjjd',
      component: choosedSjjd,
    },
    {
      path: '/calendarList',
      name: 'calendarList',
      component: calendarList,
    },
    {
      path: '/calendarDetail/:fday?/:ftype?',
      name: 'calendarDetail',
      component: calendarDetail,
    },
    {
      path: '/myTaskList/:fopportunityid?/:fbusinessid?',
      name: 'myTaskList',
      component: myTaskList,
    },
    {
      path: '/myTaskAdd/:isAdd?/:pid?/:fopportunityid?/:fnodeid?/:isDetail?',
      name: 'myTaskAdd',
      component: myTaskAdd,
    },
    {
      path: '/customerList',
      name: 'customerList',
      component: customerList,
    },
    {
      path: '/customerAdd/:isAdd?/:id?/:isDetail?',
      name: 'customerAdd',
      component: customerAdd,
    },
    {
      path: '/searchSjInfoList/:id?/:ftype?',
      name: 'searchSjInfoList',
      component: searchSjInfoList,
    },
  ]
})
